package com.carrot.uaa.domain;

import com.carrot.uaa.entity.OAuth2User;
import org.springframework.security.crypto.password.PasswordEncoder;

public interface IAuthBusinessRuleService {

    /**
     * 账号校验
     * @param oAuth2User
     * @return
     */
    void checkAccount(OAuth2User oAuth2User);

    /**
     * 验证短信验证码是否正确
     * @param account 账号
     * @param reqCaptcha 用户输入的验证码
     */
    void checkSmsCaptcha(String account,String reqCaptcha,String appName);

    /**
     * 验证密码是否正确
     * @param passwordEncoder
     * @param account
     * @param password
     * @param reqPassword
     */
    void checkPassword(PasswordEncoder passwordEncoder, String account, String password,String reqPassword);
}
